package com.yjd.comm.enums;

/**
 * 退款审核/订单状态
 * Created by yangchangyan on 2017/8/23.
 */
public enum RefundOrderStatus {

    NO_REFUND_APPLY(0, "未申请退款"),
    REFUND_PASS(1, "通过"),
    REFUND_REFUSE(2, "拒绝");

    private int code;
    private String label;

    public static RefundOrderStatus parse(int code) {
        for (RefundOrderStatus v : RefundOrderStatus.values()) {
            if (v.getCode() == code) {
                return v;
            }
        }
        return null;
    }

    private RefundOrderStatus(int code, String label) {
        this.code = code;
        this.label = label;
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getLabel() {
        return label;
    }

    public void setLabel(String label) {
        this.label = label;
    }
}
